package com.funmi.lizip.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.funmi.lizip.entity.TaskDelivery;
import com.funmi.lizip.entity.dto.taskDelivery.TaskDeliveryQueryRequest;
import com.funmi.lizip.entity.vo.TaskDeliveryVo;
import com.funmi.lizip.mapper.TaskDeliveryMapper;
import com.funmi.lizip.service.TaskDeliveryService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author itheima
 */
@Slf4j
@Service
@Transactional
public class TaskDeliveryServiceImpl extends ServiceImpl<TaskDeliveryMapper, TaskDelivery> implements TaskDeliveryService {


    @Autowired
    private TaskDeliveryMapper taskDeliveryMapper;

    @Override
    public TaskDelivery listById(TaskDeliveryQueryRequest request) {
        TaskDelivery taskDelivery = taskDeliveryMapper.selectById(request.getId());
        return taskDelivery;
    }


    @Override
    public List<TaskDelivery> getAll(TaskDeliveryQueryRequest taskDeliveryQueryRequest) {
        return taskDeliveryMapper.getAll(taskDeliveryQueryRequest);

    }
}
